# -*- coding: utf-8 -*-
# @Time    : 2021/4/20
# @File    : draft.py
import os

import torch

checkpoint_path = '../checkpoints'


def some_func(path):
	files = os.listdir(path)
	l = len(files)
	if l > 0:
		checkpoint = torch.load(f'{checkpoint_path}/{files[l - 1]}')
		print(checkpoint)
	else:
		print("Nothing")


if __name__ == '__main__':
	some_func(checkpoint_path)
